Skip to content

Conversation

@mtsgrd
Copy link
Contributor

@mtsgrd mtsgrd commented Oct 26, 2025

Instead of {type: 'claudeOutput', subject: {..}} this code now serializes messages into {claudeOutput: {..}}. This is the default format for serde, as well as protobuf and thrift.

Additionally, since these structs get serialized and stored on disk, we have to allow errors to happen on read so that we have a chance to modify the data structures.

@vercel
Copy link

vercel bot commented Oct 26, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
gitbutler-web Ready Ready Preview Comment Oct 29, 2025 10:30pm

Comment on lines 144 to 157
.filter_map(|m| {
let message_id = m.id.clone();
match m.try_into() {
Ok(msg) => Some(msg),
Err(e) => {
tracing::warn!(
message_id = %message_id,
error = %e,
"Failed to deserialize claude message, skipping"
);
None
}
}
})
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@krlvi fyi - about ignoring read errors for list_messages_by_session

mtsgrd and others added 3 commits October 29, 2025 23:28
Instead of `{type: 'claudeOutput', subject: {..}}` this code now
serializes messages into `{claudeOutput: {..}}`. This is the default
format for `serde`, as well as protobuf and thrift.

Additionally, since these structs get serialized and stored on disk, we
have to allow errors to happen on read so that we have a chance to 
modify the data structures.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

@gitbutler/desktop rust Pull requests that update Rust code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants